package vfs.common.rmi;

import vfs.common.User;
import vfs.common.command.remote.RemoteCommand;

import java.rmi.Remote;
import java.rmi.RemoteException;

/**
 * Server-side command receiver
 * <p/>
 * User: serge
 * Date: 21.11.13
 * Time: 19:17
 */
public interface RmiDispatcher extends Remote
{
    /**
     * runs Command.execute() remotely
     *
     * @param command
     */
    public void executeCommand(RemoteCommand command) throws RemoteException;

    public boolean registerUser(User user) throws RemoteException;

    public boolean unregisterUser(User user) throws RemoteException;
}
